#include <iostream>
using namespace std;

class date
{
    public:
        date(int year = 1970,int month = 1,int day = 1)
        {
            _year = year;
            _month = month;
            _day = day;
            cout << "construction of class date" << endl;
        }
        ~date()
        {
            _year = 1970;
            _month = 1;
            _day = 1;
        }
        void print()
        {
            cout << _year << "-" << _month << "-" << _day << endl;
        }
    private:
        int _year;
        int _month;
        int _day;
};

int main()
{
    date d(2024,11,18);
    d.print();
    return 0;
}
